﻿<core:XApplication x:Class="Coolzon.UI.ViewerApp.App"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:core="clr-namespace:Coolzon.UI.Core;assembly=Coolzon.UI.Core">
    <core:XApplication.Resources>
        <ResourceDictionary>
            <SolidColorBrush x:Key="color-title" Color="#333333"/>
            <Style TargetType="Button">
                <Setter Property="Width" Value="75"/>
                <Setter Property="Height" Value="34"/>
                <Setter Property="Foreground" Value="#333"/>
                <!--修改模板属性-->
                <Setter Property="Template">
                    <Setter.Value>
                        <!--控件模板-->
                        <ControlTemplate TargetType="Button">
                            <!--背景色-->
                            <Border CornerRadius="4" BorderThickness="1" BorderBrush="#adadad" Background="#e6e6e6">
                                <!--按钮内容-->
                                <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Content="{TemplateBinding Content}">
                                </ContentPresenter>
                            </Border>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
                <!--<Style.Triggers>
                    --><!--事件触发器--><!--
                    <EventTrigger RoutedEvent="MouseEnter">
                        <BeginStoryboard>
                            <Storyboard>
                                <DoubleAnimation Storyboard.TargetProperty="Opacity" From="0" To="0.5" Duration="0:0:0.5" Storyboard.Target="{Binding ElementName=highlight}"></DoubleAnimation>
                            </Storyboard>
                        </BeginStoryboard>
                    </EventTrigger>
                    <EventTrigger RoutedEvent="MouseLeave">
                        <BeginStoryboard>
                            <Storyboard>
                                <DoubleAnimation Storyboard.TargetProperty="Opacity" From="0.5" To="0" Duration="0:0:0.5" Storyboard.Target="{Binding ElementName=highlight}"></DoubleAnimation>
                            </Storyboard>
                        </BeginStoryboard>
                    </EventTrigger>
                </Style.Triggers>-->
            </Style>
            <Style x:Key="btn-primary" TargetType="Button">
                <Setter Property="Width" Value="75"/>
                <Setter Property="Height" Value="34"/>
                <Setter Property="Foreground" Value="White"/>
                <!--修改模板属性-->
                <Setter Property="Template">
                    <Setter.Value>
                        <!--控件模板-->
                        <ControlTemplate TargetType="Button">
                            <!--背景色-->
                            <Border CornerRadius="4" BorderThickness="1" BorderBrush="#2e6da4" Background="#337ab7">
                                <!--按钮内容-->
                                <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Content="{TemplateBinding Content}">
                                </ContentPresenter>
                            </Border>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
            </Style>
            <Style x:Key="btn-success" TargetType="Button">
                <Setter Property="Width" Value="75"/>
                <Setter Property="Height" Value="34"/>
                <Setter Property="Foreground" Value="White"/>
                <!--修改模板属性-->
                <Setter Property="Template">
                    <Setter.Value>
                        <!--控件模板-->
                        <ControlTemplate TargetType="Button">
                            <!--背景色-->
                            <Border CornerRadius="4" BorderThickness="1" BorderBrush="#398439" Background="#449d44">
                                <!--按钮内容-->
                                <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Content="{TemplateBinding Content}">
                                </ContentPresenter>
                            </Border>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
            </Style>
            <Style x:Key="btn-danger" TargetType="Button">
                <Setter Property="Width" Value="75"/>
                <Setter Property="Height" Value="34"/>
                <Setter Property="Foreground" Value="White"/>
                <!--修改模板属性-->
                <Setter Property="Template">
                    <Setter.Value>
                        <!--控件模板-->
                        <ControlTemplate TargetType="Button">
                            <!--背景色-->
                            <Border CornerRadius="4" BorderThickness="1" BorderBrush="#ac2925" Background="#c9302c">
                                <!--按钮内容-->
                                <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Content="{TemplateBinding Content}">
                                </ContentPresenter>
                            </Border>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
            </Style>
            <Style x:Key="btn-hoverable" TargetType="Button">
                <Setter Property="Width" Value="75"/>
                <Setter Property="Height" Value="34"/>
                <Setter Property="Foreground" Value="#333"/>
                <Setter Property="Opacity" Value="0.1"/>
                <!--修改模板属性-->
                <Setter Property="Template">
                    <Setter.Value>
                        <!--控件模板-->
                        <ControlTemplate TargetType="Button">
                            <!--背景色-->
                            <Border CornerRadius="4" BorderThickness="1" BorderBrush="#adadad" Background="#e6e6e6">
                                <!--按钮内容-->
                                <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Content="{TemplateBinding Content}">
                                </ContentPresenter>
                            </Border>
                        </ControlTemplate>
                    </Setter.Value>
                </Setter>
                <Style.Triggers>
                    <!--事件触发器-->
                    <EventTrigger RoutedEvent="MouseEnter">
                        <BeginStoryboard>
                            <Storyboard>
                                <DoubleAnimation Storyboard.TargetProperty="Opacity" From="0.1" To="1" Duration="0:0:0.5"></DoubleAnimation>
                            </Storyboard>
                        </BeginStoryboard>
                    </EventTrigger>
                    <EventTrigger RoutedEvent="MouseLeave">
                        <BeginStoryboard>
                            <Storyboard>
                                <DoubleAnimation Storyboard.TargetProperty="Opacity" From="1" To="0.1" Duration="0:0:0.5"></DoubleAnimation>
                            </Storyboard>
                        </BeginStoryboard>
                    </EventTrigger>
                </Style.Triggers>
            </Style>
        </ResourceDictionary>
    </core:XApplication.Resources>
</core:XApplication>
